import http from '@/utils/http';

export const promptApi = {
  list: (params: Record<string, any>) => {
    return http.get('/prompt/list', { params });
  },

  detail: (id: number | string) => {
    return http.get(`/prompt/${id}`);
  },

  create: (data: Record<string, any>) => {
    return http.post('/prompt', data);
  },

  update: (id: number | string, data: Record<string, any>) => {
    return http.put(`/prompt/${id}`, data);
  },

  remove: (id: number | string) => {
    return http.delete(`/prompt/${id}`);
  },
}